Cluster characteristics, mophine treatment differences, and morphine receptor expression

Figure 1A-E Cluster specific markers, UMAP, morphine receptor expression, heatmap

DefaultAssay(results)<-"RNA"

results$merged_clusters<-factor(results$merged_clusters, levels = c("NaiveT_1","NaiveT_2", "NaiveT_3","MemoryT_1","MemoryT_2",
                                                                    "MemoryT_Polarized_1","MemoryT_Polarized_2","Treg_proliferating",
                                                                    "CytotoxicT","NK","Naive_B","Memory_B","Plasma","CD14_Mono","cDC","pDC"))
Idents(results)<-results$merged_clusters

DimPlot(results, label = TRUE)+NoLegend()

pdf("~/gibbs/DOGMAMORPH/Ranalysis/Scripts/Figure Notebooks/rawFigs/fig1/A.pdf", width = 16, height = 9)
DimPlot(results, label = TRUE)+NoLegend()
dev.off()->.


Markers<-FindAllMarkers(results, only.pos=TRUE)
## Calculating cluster NaiveT_1
## Calculating cluster NaiveT_2
## Calculating cluster NaiveT_3
## Calculating cluster MemoryT_1
## Calculating cluster MemoryT_2
## Calculating cluster MemoryT_Polarized_1
## Calculating cluster MemoryT_Polarized_2
## Calculating cluster Treg_proliferating
## Calculating cluster CytotoxicT
## Calculating cluster NK
## Calculating cluster Naive_B
## Calculating cluster Memory_B
## Calculating cluster Plasma
## Calculating cluster CD14_Mono
## Calculating cluster cDC
## Calculating cluster pDC
#filter out anything without a significant adjusted P 
Markers<-Markers[Markers$p_val_adj<0.05,]
#saving markers for a table eventually
write.table(Markers,"~/gibbs/DOGMAMORPH/Ranalysis/results/FindAllMakers.tsv",sep = "\t", row.names = FALSE, quote = FALSE)

DT::datatable(rownames=TRUE, filter="top", class='cell-border stripe', extensions = 'Buttons', options = list(dom = 'Bfrtip', buttons = c('copy', 'csv', 'excel', 'pdf', 'print')), data=Markers, caption = htmltools::tags$caption( style = 'caption-side: top; text-align: center; color:black;  font-size:200% ;','Cluster markers'))
top10<-group_by(Markers, cluster)%>%slice_max(avg_log2FC, n=12)%>%select(gene)
## Adding missing grouping variables: `cluster`
top10<-unique(top10$gene)
results<-ScaleData(results, features = top10)
## Centering and scaling data matrix
DoHeatmap(results, top10, disp.min = -2, disp.max = 2)

pdf("~/gibbs/DOGMAMORPH/Ranalysis/Scripts/Figure Notebooks/rawFigs/fig1/B.pdf", width = 16, height = 9)
DoHeatmap(results, top10, disp.min = -2, disp.max = 2)
dev.off()->.

Idents(results)<-factor(results$merged_clusters, levels = rev(levels(results$merged_clusters)))

#RNA markers dotplot

RNA.marks<-c("CD3D","CD4", "SELL", "CCR7", "TCF7", "JUN","FOS","LTA","LTB","IFNG","IL2","TNF", "GATA3", "RORC",  "FOXP3","IL2RA","MKI67",
             "CD8A","GZMB", "CCL5",  "GNLY","NKG7","MS4A1","CST3","LYZ","S100A4","FCER1A","MS4A7", "FCGR3A")






DotPlot(results, features= RNA.marks) + theme(axis.text.x = element_text(angle = 90))

pdf("~/gibbs/DOGMAMORPH/Ranalysis/Scripts/Figure Notebooks/rawFigs/fig1/C.pdf", width = 16, height = 9)
DotPlot(results, features= RNA.marks) + theme(axis.text.x = element_text(angle = 90))
dev.off()->.


#ADT markers dotplot
DefaultAssay(results)<-"ADT"
results<-NormalizeData(results, normalization.method = "CLR")
## Normalizing across features
protein.marks<-c("CD3-TotalA","CD4-TotalA","CD45RO-TotalA", "CD45RA-TotalA", "CD27-TotalA", "HLA-DR-DP-DQ-TotalA", "CD183-TotalA","CX3CR1-TotalA","CD196-TotalA",
                 "CD195-TotalA","CD194-TotalA", "CD279-TotalA","TIGIT-TotalA", "CD8-TotalA", "CD56-TotalA","NKp80-TotalA", "CD19-TotalA",
                 "IgD-TotalA", "CD11b-TotalA","CD11c-TotalA", "CD86-TotalA","CD1c-TotalA")






DotPlot(results, features= protein.marks) + theme(axis.text.x = element_text(angle = 90))

pdf("~/gibbs/DOGMAMORPH/Ranalysis/Scripts/Figure Notebooks/rawFigs/fig1/D.pdf", width = 16, height = 9)
DotPlot(results, features= protein.marks) + theme(axis.text.x = element_text(angle = 90))
dev.off()->.

Figure 1F Cluster imbalance in treatment

Idents(results)<-results$merged_clusters
meta<-results@meta.data
meta$Treatment<-factor(meta$Treatment, levels = c("Methadone","Bup.Nalo","Naltrexone"))
meta$Timepoint<-factor(meta$Timepoint, levels = c(0,3))
meta_tots_by_part<-group_by(meta, Treatment,Timepoint, Participant, merged_clusters, .drop=FALSE)%>%summarise(n=n())%>%mutate(prop=n/sum(n))%>%ungroup()
## `summarise()` has grouped output by 'Treatment', 'Timepoint', 'Participant'.
## You can override using the `.groups` argument.
meta_tots_by_part<-meta_tots_by_part[!is.nan(meta_tots_by_part$prop),]
meta_tots_by_part<-split(meta_tots_by_part, meta_tots_by_part$Timepoint)

meta_tots_by_part$`3`<-meta_tots_by_part$`3`[, c("Treatment","Participant","merged_clusters","prop")]
meta_tots_by_part$`0`<-meta_tots_by_part$`0`[, c("Treatment","Participant","merged_clusters","prop")]
colnames(meta_tots_by_part$`3`)<-c("Treatment","Participant","merged_clusters","prop3")
meta_tots_by_part<-merge(meta_tots_by_part$`0`,meta_tots_by_part$`3`, by=c("Treatment","Participant","merged_clusters") )
meta_tots_by_part$FC<-log2(meta_tots_by_part$prop3/meta_tots_by_part$prop)
meta_tots_by_part$clip<-meta_tots_by_part$FC
meta_tots_by_part$clip[meta_tots_by_part$clip>3]<-3
meta_tots_by_part$clip[meta_tots_by_part$clip< -3]<- -3
ggplot(meta_tots_by_part, aes(x=merged_clusters, y=clip, group=Treatment, color=Treatment))+geom_point(position=position_dodge(width = 0.5), size=3)+theme_classic()+theme(axis.text.x = element_text(angle = 90, vjust = 0.3, hjust = 1, size = 16))+geom_hline(yintercept = 0, linetype=3)+ylab("log2(FC)")+xlab("Cluster")+ylim(c(-3.5,3.5))+ggtitle("Clipped Log2FC cluster proportions")
## Warning: Removed 2 rows containing missing values (`geom_point()`).

meta_tots_by_part$FC[is.infinite(meta_tots_by_part$FC)]<-0
meta_tots_by_part$FC[is.nan(meta_tots_by_part$FC)]<-0

twoway.anova<-aov(FC ~ Treatment * merged_clusters, meta_tots_by_part)
#p value now significant on the transformed values, follow ups justified 
summary(twoway.anova)
##                            Df Sum Sq Mean Sq F value  Pr(>F)   
## Treatment                   2   7.25   3.624   4.116 0.01827 * 
## merged_clusters            15  31.40   2.094   2.378 0.00432 **
## Treatment:merged_clusters  30  47.51   1.584   1.798 0.01215 * 
## Residuals                 144 126.79   0.881                   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
#follow up comparisons 

clusters<-names(table(meta_tots_by_part$merged_clusters))
treatments<-names(table(meta_tots_by_part$Treatment))

for(i in clusters){
  for(j in 1:3){
    if(j==3){
      k=1
    }else{
      k=j+1
    }
    resultst<-wilcox.test(meta_tots_by_part$FC[meta_tots_by_part$merged_clusters==i & meta_tots_by_part$Treatment==treatments[j]],meta_tots_by_part$FC[meta_tots_by_part$merged_clusters==i & meta_tots_by_part$Treatment==treatments[k]])
    if(resultst$p.value<0.05){
      print(i)
      print(paste(treatments[j], "vs", treatments[k]))
      print(resultst)
    }
  }
}
## [1] "NaiveT_1"
## [1] "Naltrexone vs Methadone"
## 
##  Wilcoxon rank sum exact test
## 
## data:  meta_tots_by_part$FC[meta_tots_by_part$merged_clusters == i & meta_tots_by_part$Treatment == treatments[j]] and meta_tots_by_part$FC[meta_tots_by_part$merged_clusters == i & meta_tots_by_part$Treatment == treatments[k]]
## W = 0, p-value = 0.02857
## alternative hypothesis: true location shift is not equal to 0
## 
## [1] "NaiveT_3"
## [1] "Methadone vs Bup.Nalo"
## 
##  Wilcoxon rank sum exact test
## 
## data:  meta_tots_by_part$FC[meta_tots_by_part$merged_clusters == i & meta_tots_by_part$Treatment == treatments[j]] and meta_tots_by_part$FC[meta_tots_by_part$merged_clusters == i & meta_tots_by_part$Treatment == treatments[k]]
## W = 16, p-value = 0.02857
## alternative hypothesis: true location shift is not equal to 0
## 
## [1] "CytotoxicT"
## [1] "Bup.Nalo vs Naltrexone"
## 
##  Wilcoxon rank sum exact test
## 
## data:  meta_tots_by_part$FC[meta_tots_by_part$merged_clusters == i & meta_tots_by_part$Treatment == treatments[j]] and meta_tots_by_part$FC[meta_tots_by_part$merged_clusters == i & meta_tots_by_part$Treatment == treatments[k]]
## W = 0, p-value = 0.02857
## alternative hypothesis: true location shift is not equal to 0
## 
## [1] "CytotoxicT"
## [1] "Naltrexone vs Methadone"
## 
##  Wilcoxon rank sum exact test
## 
## data:  meta_tots_by_part$FC[meta_tots_by_part$merged_clusters == i & meta_tots_by_part$Treatment == treatments[j]] and meta_tots_by_part$FC[meta_tots_by_part$merged_clusters == i & meta_tots_by_part$Treatment == treatments[k]]
## W = 16, p-value = 0.02857
## alternative hypothesis: true location shift is not equal to 0
## Warning in
## wilcox.test.default(meta_tots_by_part$FC[meta_tots_by_part$merged_clusters == :
## cannot compute exact p-value with ties
## Warning in
## wilcox.test.default(meta_tots_by_part$FC[meta_tots_by_part$merged_clusters == :
## cannot compute exact p-value with ties
## [1] "CD14_Mono"
## [1] "Methadone vs Bup.Nalo"
## 
##  Wilcoxon rank sum exact test
## 
## data:  meta_tots_by_part$FC[meta_tots_by_part$merged_clusters == i & meta_tots_by_part$Treatment == treatments[j]] and meta_tots_by_part$FC[meta_tots_by_part$merged_clusters == i & meta_tots_by_part$Treatment == treatments[k]]
## W = 16, p-value = 0.02857
## alternative hypothesis: true location shift is not equal to 0
## 
## [1] "CD14_Mono"
## [1] "Bup.Nalo vs Naltrexone"
## 
##  Wilcoxon rank sum exact test
## 
## data:  meta_tots_by_part$FC[meta_tots_by_part$merged_clusters == i & meta_tots_by_part$Treatment == treatments[j]] and meta_tots_by_part$FC[meta_tots_by_part$merged_clusters == i & meta_tots_by_part$Treatment == treatments[k]]
## W = 0, p-value = 0.02857
## alternative hypothesis: true location shift is not equal to 0
pdf("~/gibbs/DOGMAMORPH/Ranalysis/Scripts/Figure Notebooks/rawFigs/fig1/F.pdf", width = 16, height = 9)
ggplot(meta_tots_by_part, aes(x=merged_clusters, y=clip, group=Treatment, color=Treatment))+geom_point(position=position_dodge(width = 0.5), size=3)+theme_classic()+theme(axis.text.x = element_text(angle = 90, vjust = 0.3, hjust = 1, size = 16))+geom_hline(yintercept = 0, linetype=3)+ylab("log2(FC)")+xlab("Cluster")+ylim(c(-3.5,3.5))+ggtitle("Clipped Log2FC cluster proportions")
## Warning: Removed 2 rows containing missing values (`geom_point()`).
dev.off()->.

Figure 1G Maximum differences across DE

data<-readRDS("~/gibbs/DOGMAMORPH/Ranalysis/Objects/20230702AllClustersTreatmentconditionsRNA.rds")

total_DE<-c()
for(cluster in data){
  DEs=0
  for (comparison in cluster){
    DEs=DEs+sum(comparison$p_val_adj<=0.05)
  }
  total_DE<-c(total_DE, DEs)
}
names(total_DE)<-names(data)
print(total_DE)
## MemoryT_Polarized_1            NaiveT_1             Naive_B                 pDC 
##                 500                 699                 129                  35 
##          CytotoxicT            Memory_B            NaiveT_3                  NK 
##                 677                  24                 535                 133 
##  Treg_proliferating           MemoryT_1 MemoryT_Polarized_2           CD14_Mono 
##                 298                 414                 413                 125 
##                 cDC            NaiveT_2           MemoryT_2              Plasma 
##                  75                 125                   5                   3
data<-unlist(data, recursive = FALSE)

cond<-names(data)

totalDE<-function(dataframe){
  return(sum(dataframe$p_val_adj<0.05))
}



totalDifferentiallyExpressed<-unlist(lapply(data, totalDE))
res<-data.frame(cond,totalDifferentiallyExpressed)
res$cluster<-gsub(paste(c(".Methadone_3_vs_Methadone_0",   ".Bup.Nalo_3_vs_Bup.Nalo_0",     ".Naltrexone_3_vs_Naltrexone_0", ".Methadone_3_vs_Bup.Nalo_3",   
".Bup.Nalo_3_vs_Naltrexone_3",   ".Naltrexone_3_vs_Methadone_3" , ".Methadone_0_vs_Bup.Nalo_0"  ,  ".Bup.Nalo_0_vs_Naltrexone_0"  ,
".Naltrexone_0_vs_Methadone_0"), collapse = "|"),"",res$cond)

res$comp<-gsub(paste(names(table(Idents(results))),".", collapse = "|", sep = ""),"",res$cond)
res$comp<-gsub("CD14\\+_Mono.","", res$comp)
res$modality<-"RNA"

res$cluster<-factor(res$cluster, levels = levels(results$merged_clusters))

ggplot(res, aes(x=cluster, y=totalDifferentiallyExpressed, fill=comp))+geom_col(position="dodge")+theme_classic()+theme(axis.text.x = element_text(vjust = 0.3, angle = 90, hjust=1))

pdf("~/gibbs/DOGMAMORPH/Ranalysis/Scripts/Figure Notebooks/rawFigs/fig1/G.pdf", width = 16, height = 9)
ggplot(res, aes(x=cluster, y=totalDifferentiallyExpressed, fill=comp))+geom_col(position="dodge")+theme_classic()+theme(axis.text.x = element_text(vjust = 0.3, angle = 90, hjust=1))
dev.off()->.
DefaultAssay(results)<-"RNA"
opioid.genes<-c("OPRM1", "OGFR","OPRK1","OPRD1","OPRL1")
results$T_Tp<-paste(results$Treatment, results$Timepoint, sep = "_")
results$T_Tp<-factor(results$T_Tp, levels = c("Methadone_0","Methadone_3","Bup.Nalo_0", "Bup.Nalo_3", "Naltrexone_0", "Naltrexone_3"))
tlevels<-rev(c("Methadone_0","Methadone_3","Bup.Nalo_0", "Bup.Nalo_3", "Naltrexone_0", "Naltrexone_3"))
results$group<-paste(results$merged_clusters, results$T_Tp, sep="_")

clusters<-rev(levels(results$merged_clusters))

new_order<-c()
for(i in clusters){
  new_order<-c(new_order, unlist(paste(i,tlevels, sep = "_" )))
}

results<-SplitObject(results, "group")

results<-results[new_order]

results_new<-merge(results[[1]],c(results[[2]],results[[3]],results[[4]],results[[5]],results[[6]],results[[7]],results[[8]],results[[9]],results[[10]], 
                                  results[[11]],results[[12]],results[[13]],results[[14]],results[[15]],results[[16]],results[[17]],results[[18]],results[[19]],results[[20]],
                                  results[[21]],results[[22]],results[[23]],results[[24]],results[[25]],results[[26]],results[[27]],results[[28]],results[[29]],results[[30]],
                                  results[[31]],results[[32]],results[[33]],results[[34]],results[[35]],results[[36]],results[[37]],results[[38]],results[[39]],results[[40]],
                                  results[[41]],results[[42]],results[[43]],results[[44]],results[[45]],results[[46]],results[[47]],results[[48]],results[[49]],results[[50]],
                                  results[[51]],results[[52]],results[[53]],results[[54]],results[[55]],results[[56]],results[[57]],results[[58]],results[[59]],results[[60]],
                                  results[[61]],results[[62]],results[[63]],results[[64]],results[[65]],results[[66]],results[[67]],results[[68]],results[[69]],results[[70]],
                                  results[[71]],results[[72]],results[[73]],results[[74]],results[[75]],results[[76]],results[[77]],results[[78]],results[[79]],results[[80]],
                                  results[[81]],results[[82]],results[[83]],results[[84]],results[[85]],results[[86]],results[[87]],results[[88]],results[[89]],results[[90]],
                                  results[[91]],results[[92]],results[[93]],results[[94]],results[[95]],results[[96]]))
Idents(results_new)<-results_new$merged_clusters


DotPlot(results_new, features = opioid.genes, split.by = "T_Tp",cols = BottleRocket3)

pdf("~/gibbs/DOGMAMORPH/Ranalysis/Scripts/Figure Notebooks/rawFigs/fig1/E.pdf", width = 16, height = 9)
DotPlot(results_new, features = opioid.genes, split.by = "T_Tp", cols = BottleRocket3)
dev.off()->.
devtools::session_info()
## Warning in system("timedatectl", intern = TRUE): running command 'timedatectl'
## had status 1
## ─ Session info ───────────────────────────────────────────────────────────────
##  setting  value
##  version  R version 4.2.0 (2022-04-22)
##  os       Red Hat Enterprise Linux 8.9 (Ootpa)
##  system   x86_64, linux-gnu
##  ui       X11
##  language (EN)
##  collate  C.UTF-8
##  ctype    C.UTF-8
##  tz       Etc/UTC
##  date     2024-02-03
##  pandoc   3.1.1 @ /usr/lib/rstudio-server/bin/quarto/bin/tools/ (via rmarkdown)
## 
## ─ Packages ───────────────────────────────────────────────────────────────────
##  package          * version   date (UTC) lib source
##  abind              1.4-5     2016-07-21 [2] CRAN (R 4.2.0)
##  BiocGenerics       0.44.0    2022-11-01 [1] Bioconductor
##  BiocParallel       1.32.6    2023-03-17 [1] Bioconductor
##  Biostrings         2.66.0    2022-11-01 [1] Bioconductor
##  bitops             1.0-7     2021-04-24 [2] CRAN (R 4.2.0)
##  bslib              0.4.2     2022-12-16 [1] CRAN (R 4.2.0)
##  cachem             1.0.8     2023-05-01 [1] CRAN (R 4.2.0)
##  callr              3.7.3     2022-11-02 [1] CRAN (R 4.2.0)
##  cli                3.6.1     2023-03-23 [1] CRAN (R 4.2.0)
##  cluster            2.1.4     2022-08-22 [2] CRAN (R 4.2.0)
##  codetools          0.2-19    2023-02-01 [2] CRAN (R 4.2.0)
##  colorspace         2.1-0     2023-01-23 [2] CRAN (R 4.2.0)
##  cowplot            1.1.1     2020-12-30 [2] CRAN (R 4.2.0)
##  crayon             1.5.2     2022-09-29 [2] CRAN (R 4.2.0)
##  crosstalk          1.2.0     2021-11-04 [2] CRAN (R 4.2.0)
##  data.table         1.14.8    2023-02-17 [2] CRAN (R 4.2.0)
##  DBI                1.1.3     2022-06-18 [2] CRAN (R 4.2.0)
##  deldir             1.0-6     2021-10-23 [2] CRAN (R 4.2.0)
##  devtools           2.4.5     2022-10-11 [1] CRAN (R 4.2.0)
##  digest             0.6.31    2022-12-11 [2] CRAN (R 4.2.0)
##  dplyr            * 1.1.2     2023-04-20 [1] CRAN (R 4.2.0)
##  DT                 0.28      2023-05-18 [1] CRAN (R 4.2.0)
##  ellipsis           0.3.2     2021-04-29 [2] CRAN (R 4.2.0)
##  evaluate           0.20      2023-01-17 [2] CRAN (R 4.2.0)
##  fansi              1.0.4     2023-01-22 [2] CRAN (R 4.2.0)
##  farver             2.1.1     2022-07-06 [2] CRAN (R 4.2.0)
##  fastmap            1.1.1     2023-02-24 [1] CRAN (R 4.2.0)
##  fastmatch          1.1-3     2021-07-23 [2] CRAN (R 4.2.0)
##  fitdistrplus       1.1-8     2022-03-10 [2] CRAN (R 4.2.0)
##  fs                 1.6.1     2023-02-06 [2] CRAN (R 4.2.0)
##  future             1.32.0    2023-03-07 [1] CRAN (R 4.2.0)
##  future.apply       1.10.0    2022-11-05 [1] CRAN (R 4.2.0)
##  generics           0.1.3     2022-07-05 [2] CRAN (R 4.2.0)
##  GenomeInfoDb       1.34.9    2023-02-02 [1] Bioconductor
##  GenomeInfoDbData   1.2.9     2023-03-17 [1] Bioconductor
##  GenomicRanges      1.50.2    2022-12-16 [1] Bioconductor
##  ggplot2          * 3.4.2     2023-04-03 [1] CRAN (R 4.2.0)
##  ggrepel            0.9.3     2023-02-03 [1] CRAN (R 4.2.0)
##  ggridges           0.5.4     2022-09-26 [1] CRAN (R 4.2.0)
##  globals            0.16.2    2022-11-21 [1] CRAN (R 4.2.0)
##  glue               1.6.2     2022-02-24 [2] CRAN (R 4.2.0)
##  goftest            1.2-3     2021-10-07 [2] CRAN (R 4.2.0)
##  gridExtra          2.3       2017-09-09 [2] CRAN (R 4.2.0)
##  gtable             0.3.3     2023-03-21 [1] CRAN (R 4.2.0)
##  highr              0.10      2022-12-22 [1] CRAN (R 4.2.0)
##  htmltools          0.5.5     2023-03-23 [1] CRAN (R 4.2.0)
##  htmlwidgets        1.6.2     2023-03-17 [1] CRAN (R 4.2.0)
##  httpuv             1.6.9     2023-02-14 [1] CRAN (R 4.2.0)
##  httr               1.4.5     2023-02-24 [1] CRAN (R 4.2.0)
##  ica                1.0-3     2022-07-08 [2] CRAN (R 4.2.0)
##  igraph             1.4.2     2023-04-07 [1] CRAN (R 4.2.0)
##  IRanges            2.32.0    2022-11-01 [1] Bioconductor
##  irlba              2.3.5.1   2022-10-03 [1] CRAN (R 4.2.0)
##  jquerylib          0.1.4     2021-04-26 [2] CRAN (R 4.2.0)
##  jsonlite           1.8.4     2022-12-06 [2] CRAN (R 4.2.0)
##  KernSmooth         2.23-20   2021-05-03 [2] CRAN (R 4.2.0)
##  knitr              1.42      2023-01-25 [1] CRAN (R 4.2.0)
##  labeling           0.4.2     2020-10-20 [2] CRAN (R 4.2.0)
##  later              1.3.0     2021-08-18 [2] CRAN (R 4.2.0)
##  lattice            0.21-8    2023-04-05 [1] CRAN (R 4.2.0)
##  lazyeval           0.2.2     2019-03-15 [2] CRAN (R 4.2.0)
##  leiden             0.4.3     2022-09-10 [1] CRAN (R 4.2.0)
##  lifecycle          1.0.3     2022-10-07 [1] CRAN (R 4.2.0)
##  limma              3.54.2    2023-02-28 [1] Bioconductor
##  listenv            0.9.0     2022-12-16 [2] CRAN (R 4.2.0)
##  lmtest             0.9-40    2022-03-21 [2] CRAN (R 4.2.0)
##  magrittr           2.0.3     2022-03-30 [2] CRAN (R 4.2.0)
##  MASS               7.3-59    2023-04-21 [1] CRAN (R 4.2.0)
##  Matrix             1.5-4     2023-04-04 [1] CRAN (R 4.2.0)
##  matrixStats        0.63.0    2022-11-18 [2] CRAN (R 4.2.0)
##  memoise            2.0.1     2021-11-26 [2] CRAN (R 4.2.0)
##  mime               0.12      2021-09-28 [2] CRAN (R 4.2.0)
##  miniUI             0.1.1.1   2018-05-18 [2] CRAN (R 4.2.0)
##  munsell            0.5.0     2018-06-12 [2] CRAN (R 4.2.0)
##  nlme               3.1-162   2023-01-31 [1] CRAN (R 4.2.0)
##  parallelly         1.35.0    2023-03-23 [1] CRAN (R 4.2.0)
##  patchwork          1.1.2     2022-08-19 [1] CRAN (R 4.2.0)
##  pbapply            1.7-0     2023-01-13 [1] CRAN (R 4.2.0)
##  pillar             1.9.0     2023-03-22 [1] CRAN (R 4.2.0)
##  pkgbuild           1.4.0     2022-11-27 [1] CRAN (R 4.2.0)
##  pkgconfig          2.0.3     2019-09-22 [2] CRAN (R 4.2.0)
##  pkgload            1.3.2     2022-11-16 [1] CRAN (R 4.2.0)
##  plotly             4.10.1    2022-11-07 [1] CRAN (R 4.2.0)
##  plyr               1.8.8     2022-11-11 [1] CRAN (R 4.2.0)
##  png                0.1-8     2022-11-29 [1] CRAN (R 4.2.0)
##  polyclip           1.10-4    2022-10-20 [1] CRAN (R 4.2.0)
##  prettyunits        1.1.1     2020-01-24 [2] CRAN (R 4.2.0)
##  processx           3.8.1     2023-04-18 [1] CRAN (R 4.2.0)
##  profvis            0.3.8     2023-05-02 [1] CRAN (R 4.2.0)
##  progressr          0.13.0    2023-01-10 [1] CRAN (R 4.2.0)
##  promises           1.2.0.1   2021-02-11 [2] CRAN (R 4.2.0)
##  ps                 1.7.5     2023-04-18 [1] CRAN (R 4.2.0)
##  purrr              1.0.1     2023-01-10 [1] CRAN (R 4.2.0)
##  R6                 2.5.1     2021-08-19 [2] CRAN (R 4.2.0)
##  RANN               2.6.1     2019-01-08 [2] CRAN (R 4.2.0)
##  RColorBrewer       1.1-3     2022-04-03 [2] CRAN (R 4.2.0)
##  Rcpp               1.0.10    2023-01-22 [1] CRAN (R 4.2.0)
##  RcppAnnoy          0.0.20    2022-10-27 [1] CRAN (R 4.2.0)
##  RcppRoll           0.3.0     2018-06-05 [2] CRAN (R 4.2.0)
##  RCurl              1.98-1.12 2023-03-27 [1] CRAN (R 4.2.0)
##  remotes            2.4.2     2021-11-30 [2] CRAN (R 4.2.0)
##  reshape2           1.4.4     2020-04-09 [2] CRAN (R 4.2.0)
##  reticulate         1.28      2023-01-27 [1] CRAN (R 4.2.0)
##  rlang              1.1.1     2023-04-28 [1] CRAN (R 4.2.0)
##  rmarkdown          2.22      2023-06-01 [1] CRAN (R 4.2.0)
##  ROCR               1.0-11    2020-05-02 [2] CRAN (R 4.2.0)
##  Rsamtools          2.14.0    2022-11-01 [1] Bioconductor
##  rstudioapi         0.14      2022-08-22 [1] CRAN (R 4.2.0)
##  Rtsne              0.16      2022-04-17 [2] CRAN (R 4.2.0)
##  S4Vectors          0.36.2    2023-02-26 [1] Bioconductor
##  sass               0.4.5     2023-01-24 [1] CRAN (R 4.2.0)
##  scales             1.2.1     2022-08-20 [1] CRAN (R 4.2.0)
##  scattermore        0.8       2022-02-14 [1] CRAN (R 4.2.0)
##  sctransform        0.3.5     2022-09-21 [1] CRAN (R 4.2.0)
##  sessioninfo        1.2.2     2021-12-06 [2] CRAN (R 4.2.0)
##  Seurat           * 4.3.0     2022-11-18 [1] CRAN (R 4.2.0)
##  SeuratObject     * 4.1.3     2022-11-07 [1] CRAN (R 4.2.0)
##  shiny              1.7.4     2022-12-15 [1] CRAN (R 4.2.0)
##  Signac           * 1.9.0     2022-12-08 [1] CRAN (R 4.2.0)
##  sp                 1.6-0     2023-01-19 [1] CRAN (R 4.2.0)
##  spatstat.data      3.0-1     2023-03-12 [1] CRAN (R 4.2.0)
##  spatstat.explore   3.1-0     2023-03-14 [1] CRAN (R 4.2.0)
##  spatstat.geom      3.1-0     2023-03-12 [1] CRAN (R 4.2.0)
##  spatstat.random    3.1-4     2023-03-13 [1] CRAN (R 4.2.0)
##  spatstat.sparse    3.0-1     2023-03-12 [1] CRAN (R 4.2.0)
##  spatstat.utils     3.0-2     2023-03-11 [1] CRAN (R 4.2.0)
##  stringi            1.7.12    2023-01-11 [1] CRAN (R 4.2.0)
##  stringr            1.5.0     2022-12-02 [1] CRAN (R 4.2.0)
##  survival           3.5-5     2023-03-12 [1] CRAN (R 4.2.0)
##  tensor             1.5       2012-05-05 [2] CRAN (R 4.2.0)
##  tibble             3.2.1     2023-03-20 [1] CRAN (R 4.2.0)
##  tidyr            * 1.3.0     2023-01-24 [1] CRAN (R 4.2.0)
##  tidyselect         1.2.0     2022-10-10 [1] CRAN (R 4.2.0)
##  urlchecker         1.0.1     2021-11-30 [1] CRAN (R 4.2.0)
##  usethis            2.1.6     2022-05-25 [1] CRAN (R 4.2.0)
##  utf8               1.2.3     2023-01-31 [1] CRAN (R 4.2.0)
##  uwot               0.1.14    2022-08-22 [1] CRAN (R 4.2.0)
##  vctrs              0.6.2     2023-04-19 [1] CRAN (R 4.2.0)
##  viridisLite        0.4.2     2023-05-02 [1] CRAN (R 4.2.0)
##  withr              2.5.0     2022-03-03 [2] CRAN (R 4.2.0)
##  xfun               0.39      2023-04-20 [1] CRAN (R 4.2.0)
##  xtable             1.8-4     2019-04-21 [2] CRAN (R 4.2.0)
##  XVector            0.38.0    2022-11-01 [1] Bioconductor
##  yaml               2.3.7     2023-01-23 [1] CRAN (R 4.2.0)
##  zlibbioc           1.44.0    2022-11-01 [1] Bioconductor
##  zoo                1.8-12    2023-04-13 [1] CRAN (R 4.2.0)
## 
##  [1] /gpfs/gibbs/project/ya-chi_ho/jac369/R/4.2
##  [2] /vast/palmer/apps/avx2/software/R/4.2.0-foss-2020b/lib64/R/library
## 
## ──────────────────────────────────────────────────────────────────────────────